# 视图文件
from django.http import HttpResponse

# 视图函数
def index(request):
    """
    视图函数：接收用户的请求，处理请求，返回响应
    :param request:包含请求信息的请求对象
    :return:返回响应对象
    """
    return HttpResponse("hello everyone")

# 返回模板
from django.shortcuts import render_to_response
def index_q(request):
    # name = "zhangsan"
    # age = 23
    # hobby = ["学习","睡觉","吃饭"]
    param = {"name":"刘爱","age":18,"hobby":["吃饭","睡觉","打豆豆"]}
    return render_to_response("index.html",param)

def demo(request):
    return render_to_response("demo.html")



